#include <iostream>
#include <vector>
using namespace std;

void Add(vector<int>& num1,vector<int>& num2,vector<int>& sum,int maxLen)
{
	int lowAdd=0;
	for(int i=0;i<maxLen;i++)
	{
		int t=lowAdd;
		if(num1.size()>i)
		{
			t+=num1[i];
		}
		if(num2.size()>i)
		{
			t+=num2[i];
		}
		sum.push_back(t%10);
		lowAdd=t/10;
	}
	if(lowAdd)
		sum.push_back(lowAdd);
	
}
void Print(vector<int>& sum)
{
	int pos=sum.size()-1;
	while(pos>=0 && sum[pos]==0)
	{
		pos--;
	}
	if(pos==-1)
	{
		cout<<0<<endl;
	}
	while(pos>=0)
	{
		cout<<sum[pos--];
	}
}
int main()
{
	string t1,t2;
	cin>>t1>>t2;
	vector<int> num1,num2,sum;
	for(int i=t1.size()-1;i>=0;i--)
	{
		num1.push_back(t1[i]-'0');
	}
	for(int i=t2.size()-1;i>=0;i--)
	{
		num2.push_back(t2[i]-'0');
	}
	Add(num1,num2,sum,max(num1.size(),num2.size()));
	Print(sum);
	return 0;
}
